package com.whstudio.common.memory.pool;

import java.util.HashMap;
import java.util.Map;

import com.whstudio.util.mvc.bo.IControlBO;

public class ControlBOPools{
	protected static Map<String,ControlBOPool> pools=new HashMap<String,ControlBOPool>();
	
	public static ControlBOPool getPool(String className){
		ControlBOPool pool=pools.get(className);
		if(pool==null){
			pool=new ControlBOPool(className);
			pools.put(className, pool);
		}
		return pool;
	}
	
	public static IControlBO getObject(String className){
		return getPool(className).getObject();
	}
	
}
